<script setup lang="ts">
let students=[{name:"张三",sn:"111"},{name:"李四",sn:"222"},{name:"王五",sn:"333"},{name:"小六",sn:"444"},{name: "小七",sn:"555"}]
</script>

<template>
  <div>
    <table>
      <tr>
        <td>序号</td>
        <td>姓名</td>
        <td>学号</td>
      </tr>
      <tr v-for="(item,index) in students" :key="index">
        <td>{{index+1}}</td>
        <td>{{item.name}}</td>
        <td>{{item.sn}}</td>

      </tr>
    </table>
  </div>
</template>

<style scoped>

</style>